package com.competition;

/**
 * 合并两个数组
 */
public class GetConcatenation {
    public static void main(String[] args) {
        int nums[] = {1,2,1};
        int[] arr = new int[nums.length * 2];
        int k = 0;
        for (int i=0;i<nums.length * 2;i++){
            if(k == nums.length){
                k = 0;
                arr[i] = nums[k];
            }else{
                arr[i] = nums[k];
            }
            k++;
        }

        for (int i:arr) {
            System.out.println(i);
        }
    }
}
